<div [formGroup]="form">
  <span class="title">{{label}}</span>
  <mat-chip-list>
    <mat-chip *ngFor="let member of items" color="primary" selected>{{member.name}}
      <span class="remove-tag" (click)="removeMember(member)">
        ×
      </span>
    </mat-chip>
  </mat-chip-list>
  <mat-form-field class="example-full-width" color="primary">
    <input matInput [placeholder]="placeholderText" [matAutocomplete]="auto" formControlName="memberSearch"*ngIf="displayInput">
    <mat-autocomplete #auto="matAutocomplete">
      <mat-option *ngFor="let item of memberResult$ |async"
                   [value]="item.name"
                   (onSelectionChange)="handleMemberSelection(item)">
         {{item.name}}
      </mat-option>
    </mat-autocomplete>
  </mat-form-field>
</div>
